package com.eighteen.table.to.xml;

import java.io.IOException;
import java.sql.SQLException;

import com.eighteen.table.to.xml.entity.ColumnEntity;
import com.eighteen.table.to.xml.service.SysGeneratorService;


public class GeneratorTable {
	
	 //数据库用户名  
    public static final String USERNAME = "root";  
    //数据库密码  
    public static final String PASSWORD = "123456";  
    //驱动信息   
    public static final String DRIVER = "com.mysql.jdbc.Driver";  
    //数据库地址  
    public static final String URL = "jdbc:mysql://127.0.0.1:3307/beimi?useSSL=false&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=convertToNull";  
	
	
	
	public static void main(String[] args) throws IOException, SQLException {
		String[] tableNames = new String[]{"bm_account_config","bm_attachment_file","bm_datadic","bm_game_ai","bm_game_group","bm_game_groupitem","bm_game_mjcardstype","bm_game_model_copy","bm_game_playway","bm_game_room","bm_gameconfig","bm_generation","bm_organ","bm_organrole","bm_playuser","bm_project","bm_role","bm_role_auth","bm_secret","bm_sysdic","bm_systemconfig","bm_tableproperties","bm_tabletask","bm_team","bm_templet","bm_user","bm_userrole","test_table"};
		SysGeneratorService sysGeneratorService = new SysGeneratorService();
		String filePath = sysGeneratorService.generatorCode(tableNames);
		System.out.println("文件已生成,文件目录："+filePath);
	}
				
}

